<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
</head>

<body>
    <div id="box">
        
         <!--包含选择器/子选择器/兄弟选择器/相邻选择器-->

      <div class="main">
        <span>1<img src="img/1.jpg"/> </span> 2
        <img src="img/1.jpg" />
    </div>

    3<img src="img/1.jpg"> 4
    <img src="img/1.jpg">

    <div>
        5<img src="img/1.jpg">
    </div>  
    </div>
    <script src="./lib/jquery.min.js"></script>
   

    <script type="text/javascript" src="js/jquery.js"></script>
    <script type="text/javascript">
        $(function () {
            // $(".main img").css("border", "5px solid red");
            // $(".main > img").css("border", "5px solid blue");
            // $(".main + img").css("border", "5px solid blue");
            $(".main ~ img").css("border", "5px solid blue");
        });
    </script>

</body>

</html>